<template>
  <div class="progress-container">
    <div class="progress-bar" :style="{ width: `${progress}%` }">
        <div class="progress-text">{{ progress }}%</div>
    </div>
  </div>
</template>

<script lang="ts" setup>
defineProps({
  progress: {
    type: Number,
    required: true,
    default: 0,
    validator: (value: number) => value >= 0 && value <= 100
  }
});
</script>

<style scoped>
.progress-container {
  width: 100%;
  height: 24px;
  background-color: #f3f4f6;
  border-radius: 10px;
  margin: 1rem 0;
  position: relative;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background-color: #629e02;
  transition: width 0.3s ease;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.progress-text {
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 500;
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.5);
}
</style>
